package com.scyshkj.university.wechat.wanxiao;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.scyshkj.university.wechat.utils.ParameterToMap;
import lombok.Data;

/**
 * Created by 唐旭 on 2016/11/20.
 */
@Data
public class WanxiaoLoginParameter implements ParameterToMap {
    @JsonProperty("client_id")
    private String clientId;

    @JsonProperty("redirect_uri")
    private String redirectUri;

    @JsonProperty("response_type")
    private String responseType = "code";

    private int display = 2;

    private Boolean reLogin;

    @JsonProperty("force_login")
    private Boolean forceLogin;

    private String state;

    @JsonProperty("login_type")
    private String loginType;

    @JsonProperty("force_bind_ecard")
    private Boolean forceBindEcard;

    private String realname;

    @JsonProperty("customer_code")
    private String customerCode;

    private Boolean hidden;

    private String outid;

    private String token;

    public WanxiaoLoginParameter() {
    }

    public WanxiaoLoginParameter(WanxiaoProperties properties) {
        this.setClientId(properties.getClientId());
        this.redirectUri = properties.getRedirectUrl();
    }
}
